package com.ruoyi.pom.service.impl;

import java.util.List;
import com.ruoyi.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.pom.mapper.PomRecallTasksMapper;
import com.ruoyi.pom.domain.PomRecallTasks;
import com.ruoyi.pom.service.IPomRecallTasksService;

/**
 * recallService业务层处理
 * 
 * @author ruoyi
 * @date 2025-01-10
 */
@Service
public class PomRecallTasksServiceImpl implements IPomRecallTasksService 
{
    @Autowired
    private PomRecallTasksMapper pomRecallTasksMapper;

    /**
     * 查询recall
     * 
     * @param id recall主键
     * @return recall
     */
    @Override
    public PomRecallTasks selectPomRecallTasksById(Long id)
    {
        return pomRecallTasksMapper.selectPomRecallTasksById(id);
    }

    /**
     * 查询recall列表
     * 
     * @param pomRecallTasks recall
     * @return recall
     */
    @Override
    public List<PomRecallTasks> selectPomRecallTasksList(PomRecallTasks pomRecallTasks)
    {
        return pomRecallTasksMapper.selectPomRecallTasksList(pomRecallTasks);
    }

    /**
     * 新增recall
     * 
     * @param pomRecallTasks recall
     * @return 结果
     */
    @Override
    public int insertPomRecallTasks(PomRecallTasks pomRecallTasks)
    {
        pomRecallTasks.setCreateTime(DateUtils.getNowDate());
        return pomRecallTasksMapper.insertPomRecallTasks(pomRecallTasks);
    }

    /**
     * 修改recall
     * 
     * @param pomRecallTasks recall
     * @return 结果
     */
    @Override
    public int updatePomRecallTasks(PomRecallTasks pomRecallTasks)
    {
        pomRecallTasks.setUpdateTime(DateUtils.getNowDate());
        return pomRecallTasksMapper.updatePomRecallTasks(pomRecallTasks);
    }

    /**
     * 批量删除recall
     * 
     * @param ids 需要删除的recall主键
     * @return 结果
     */
    @Override
    public int deletePomRecallTasksByIds(Long[] ids)
    {
        return pomRecallTasksMapper.deletePomRecallTasksByIds(ids);
    }

    /**
     * 删除recall信息
     * 
     * @param id recall主键
     * @return 结果
     */
    @Override
    public int deletePomRecallTasksById(Long id)
    {
        return pomRecallTasksMapper.deletePomRecallTasksById(id);
    }
}
